#pragma once

#include <string>
#include <list>
#include "ResipTesterDlg.h"

class CDatabaseAdaptor
{
private:
    CDatabaseAdaptor(CResipTesterDlg& dlg);

public:

	static CDatabaseAdaptor* getInstance(CResipTesterDlg* dlg = 0);

    ~CDatabaseAdaptor(void);

    bool existUpHost(std::string& host);

    bool existDownHost(std::string& host);

    bool existUp();

    bool existDown();

    bool registeredHost(std::string& host);

    bool pushRegHost(std::string& host);

    std::string queryDevice(std::string& devName);

    /*std::string querySipDown();

	std::string queryDown();

	std::string queryUp();*/

    bool canForceFail();

    bool canB2bDispatch();

public:

    std::list<std::string> m_regHostList;

	CResipTesterDlg& m_dlg;

	static CDatabaseAdaptor* s_instance;
};
